java get current time in seconds

97

java get current time in seconds -

LocalDateTime date = LocalDateTime.now();
int seconds = date.toLocalTime().toSecondOfDay();

Comments

Submit
0 Comments